[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
FREWIND IEXP
Function
Rewind an open file specified by channel IEXP after flushing buffers
and committing the file to disk.
Syntax
FREWIND chan
chan - An integer expression with the open channel to rewind
(0 through 7).
Remarks
This statement should be used when you need to rewind a file channel
after it has been created/opened with an FCREATE, FOPEN, or FAPPEND
statement. Rewinding a file channel will flush file buffers, commit the
file to disk, and reposition the file pointer to the beginning of the
file. Useful when you need to start over processing a file that may have
changed and don't want to close and re-open the file.
Examples
STRING s
FAPPEND 1,"C:\PCB\MAIN\PPE.LOG",O_RW,S_DN
FPUTLN 1,U_NAME()
FREWIND 1
WHILE (!FERR(1)) DO
FGET 1,s
PRINTLN s
ENDWHILE
FCLOSE 1
See Also:
FAPPEND
FCLOSE
FCREATE
FOPEN
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson